package org.jeecg.modules.demo.test.controller;

import org.jeecg.modules.demo.test.entity.Classroom;
import org.jeecg.modules.demo.test.service.ClassroomService;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/classroom")
@RequiredArgsConstructor
public class ClassroomController {

    private final ClassroomService classroomService;


    @GetMapping("list")
    public List<Classroom> list(){
        return classroomService.list();
    }
}
